ALL: WEATHER_CONTENT_SERVER WEATHER_COMMON WEATHER_CLIENT WEATHER_AGGREGATION_SERVER MOVE

SRC_DIR_CONTENT_SERVER = weather-content-server/src/main/java/ContentServer
JAVA_FILES_CONTENT_SERVER = $(wildcard $(SRC_DIR_CONTENT_SERVER)/*.java)

WEATHER_CONTENT_SERVER: $(JAVA_FILES_CONTENT_SERVER)
	javac $(JAVA_FILES_CONTENT_SERVER) -classpath fastjson-1.2.83.jar

SRC_DIR_WEATHEAR_COMMON = weather-common/src/main/java/common
JAVA_FILES_WEATHEAR_COMMON = $(wildcard $(SRC_DIR_WEATHEAR_COMMON)/*.java)

WEATHER_COMMON: $(JAVA_FILES_WEATHEAR_COMMON)
	javac $(JAVA_FILES_WEATHEAR_COMMON) -classpath fastjson-1.2.83.jar:junit-4.13.2.jar

SRC_DIR_WEATHEAR_CLIENT = weather-client/src/main/java/GetClient
JAVA_FILES_WEATHEAR_CLIENT = $(wildcard $(SRC_DIR_WEATHEAR_CLIENT)/*.java)

WEATHER_CLIENT: $(JAVA_FILES_WEATHEAR_CLIENT)
	javac $(JAVA_FILES_WEATHEAR_CLIENT) -classpath fastjson-1.2.83.jar

#weather/weather-Aggregation-server

SRC_DIR_WEATHEAR_AGGREGATION_SERVER = weather-Aggregation-server/src/main/java/AggregationServer
JAVA_FILES_AGGREGATION_SERVER = $(wildcard $(SRC_DIR_WEATHEAR_AGGREGATION_SERVER)/*.java)

WEATHER_AGGREGATION_SERVER: $(JAVA_FILES_AGGREGATION_SERVER)
	javac $(JAVA_FILES_AGGREGATION_SERVER) -classpath fastjson-1.2.83.jar

MOVE: $(SRC_DIR_CONTENT_SERVER)
	mv $(SRC_DIR_CONTENT_SERVER)/*.class ./
	mv $(SRC_DIR_WEATHEAR_COMMON)/*.class ./
	mv $(SRC_DIR_WEATHEAR_CLIENT)/*.class ./
	mv $(SRC_DIR_WEATHEAR_AGGREGATION_SERVER)/*.class ./